package com.rykj.energy.database.service;

import com.rykj.energy.common.utils.Result;
import com.rykj.energy.database.pojo.BasicCamera;
import com.rykj.energy.database.pojo.BasicCameraPresetting;
import com.rykj.energy.database.pojo.vo.DeviceVo;
import net.anumbrella.seaweedfs.core.file.FileHandleStatus;

import java.util.List;

public interface ICameraService {
    
    void getVoToCamera(DeviceVo deviceVo, BasicCamera camera);

    Result checkCamera(BasicCamera camera);

    BasicCamera addCamera(BasicCamera camera, List<BasicCameraPresetting> cameraPresets) throws Exception;

    List<BasicCamera> findByIp(String devIp);

    FileHandleStatus getCameraImg(BasicCamera camera) throws Exception;

    List<BasicCamera> findByChannelAlias(String camAlias);

    List<BasicCamera> findByIpAndChannelIndex(String camIp, Integer camIndex);

    List<BasicCamera> findByRtspUrl(String rtspUrl);

    void deleteByDevId(Integer devId);

    void saveCameras(List<BasicCamera> cameras) throws Exception;

    void deleteCamera(Integer cameraId) throws Exception;

    void updateCamera(BasicCamera camera,List<BasicCameraPresetting> cameraPresets) throws Exception;

    BasicCamera findById(Integer cameraId);

    void updateCameraLineStatus(BasicCamera camera);

    List<BasicCamera> getAllCameras();

    BasicCamera getCameraByCluster(String ca);

    BasicCamera findInfoByCameraNo(String cameraNo);

    /**
     *
     * @param cameraNo  通道id
     * @param code  预置点编号
     * @return
     */
    boolean sdkPresetPoint(String cameraNo,Integer code) throws Exception;

    String saveRtspUrlByCameraInfo(BasicCamera camera);
}
